﻿using System.Collections.ObjectModel;
using UpperComputer.Application;

namespace UpperComputer.WPF.Entry.Models
{
    public class MenuModel : BaseMenuResultDto
    {
        private bool _isExpanded;
        public bool IsExpanded
        {
            get => _isExpanded;
            set => SetProperty(ref _isExpanded, value);
        }

        private BaseMenuResultDto _selectedMenu;
        public BaseMenuResultDto SelectedMenu
        {
            get => _selectedMenu;
            set => SetProperty(ref _selectedMenu, value);
        }
    }

    public class CheckedMenuModel : BaseMenuResultDto
    {
        public CheckedMenuModel()
        {
            CheckedChildrens = new ObservableCollection<CheckedMenuModel>();
        }

        private bool _isChecked;
        public bool IsChecked
        {
            get => _isChecked;
            set => SetProperty(ref _isChecked, value);
        }

        public CheckedMenuModel CheckedParent { get; set; }

        public ObservableCollection<CheckedMenuModel> CheckedChildrens { get; set; }
    }
}
